Skip to main content

Full text of "Arduino"

See other formats


Networked On Air Light 



i 



Make Projects 



build, hack, tweak, share, discover, J 



Networked On Air Light 

Written By: Matt Richardson 



f TOOLS: 



Rotary Tool (1) 

Soldering iron (1) 

Wire cutter/stripper (1) 

XBee Adapter (1) 

For configuring your XBee radio. Many 
options available. Also can use your 
Arduino as a serial pass through. 



© PARTS: 



ConnectPortX2(1) 

Be sure you're ordering part number X2- 
Z1 1-EC-A as there are a lot of variants 
on this product. 

XBee Series 2 Wireless Module (1) 
There are lots of variants of this part. 
You can't go wrong with part number 
XB24-Z7WIT-004. 

Arduino microcontroller (1) 

XBee Shield (1) 

Any other kind of XBee adapter will 

work. This one sits nicely on top of the 

Arduino. 

Wall-Mount Oval Bulkhead Light (1) 
Any wall -mount light will do. The style of 
this one goes nicely with this project. 

Relay Circuit Board (1) 
Make your own or order a premade 
relay. Used to close the AC circuit using 
the digital pin of the Arduino. 

Cradled Wood Panel (1) 



© Make Projects 



www.makeprojects.com 



Page 1 of 9 



Networked On Air Light 



Available at art supply stores near the 



canvases 

Peel & Stick Vinyl Letters (1 pkg) 
Can be found at an office supply or art 
supply store. 

Lamp cord (1) 

Cube tap extension cord (1) 

Velcro (6") 

Or use another mounting method such 

as standoffs or mounting tape. 

Lightbulb (1) 

Look for "party" light bulbs 



SUMMARY 



You may have seen those "On Air" lights at film, radio or television studios. Now that anyone 
can broadcast video over the internet, it's time to learn how to build your own "Now 
Streaming" light that even wirelessly checks to see if you're streaming! 

This guide will show you how to: 

Set up the XBee Internet Gatewav Connect your XBee to an Arduino to poll a web server for dataUse Ust ream's API to 
check if a channel is broadcastingUse a relay to control an incandescent light fixtureMount the light fixture a wood 
panel 



© Make Projects 



www.makeprojects.com 



Page 2 of 9 



Networked On Air Light 




Using your rotary tool, cut a hole in the cradled panel for the light fixture's wires and pull 
the wires through to the back. 





Solder one wire from the light 
fixture to the relay. 

Cut the lamp cord to about 10 
inches from the plug, split and trim 
the wires. 

Connect one lamp cord wire to the 
relay and the other to the free lamp 
wire 



© Make Projects 



www.makeprojects.com 



Page 3 of 9 



Networked On Air Light 




^ ■>• a cd Gode.9009it.wm/ujfxig/ 


& * 




My fasciites t I Sion in f 


XBee 1 nte*ne( Gateway for lbs Digi Goonee-IPod 


I^SMrth [SfOj«Bj 


Project Hem a Downloads Witt Issues Source 



Summery updauss People 



Project Information 

Aeliifihr •■ Medium 
Project feeds 

Cede license 
GNU Lww GPL 

Label* 

XBee. Python. 
DigiCcrntKtPcft, ZigBw 

* * Members 

liminasl (ginmail com. 
aoofai .g3jqma.ii.cQnn . 
■Jordan H ©gmaiLcHn 
1 eommilltiJ 

Featured 

al Downleads 
nin-1.1.1-bJn.ziD 
Show all t 

Wlkf pagea 

lnEroduetk>n 
■Shaw all » 



The XBeg tntetrrt Gateway is a powerful Python program for the Digi ConnectPort ^ series of RF-to- 
ip aatewiiys wruch allows XBe* end dfiw*w& lo access 1he internal resources such as w<* pagos. 

FollO* M* on Twitte/ . htto:JJtwiHaf.comJ)ciqCfOiect 

The project was initialed by Rob Ffllyq> at I TP ; im piemen ted by Jordan Husney 
http:JVjonJan husnaycom and Ted Hayes httpfflop liminastudio com 



Release Malory: 



im n — in — 1 zrzz 1 — 1 \ 1 — 

vl . 1 . 1 08-Feb-20i 1 Bug fixes: "7 URL que/y string Imncation fix, URL parse failure- fix 
1/1.1.0 l?-Nou-201Q Added transmission reliability layer, bug fixes 



v 1 .0.0 25-Sep-20 10 I nitial release for M ah er Fairs IMYC 








f ■* C A O I0.0.1.L7j , configy application 5/pyth.o.njfiles. htm 


^m 


Connect Port X2 Configuration and Management 




Home 


Python Configuration 


Configuration 

Neiworff 

K3ee Network 

System 

Remote Management 

Security 

Applications 

Python 

Management 

Connections 
Event Logging 

Administration 

File Management 
Backup/ Re store 
Update Firmware 
Factory Default Settings 
System Information 
RififcOOt 

Logout 


^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 


» Pyttrofi Pitas 
Upload Files 

upload Python programs 


Upload Filer | ^ClKKSi* FilOslo tile elMMa 




(_Upteid; 

'■'■ Huge z hi 
Action Fita Name Size 


ngbee.py 1147 bytes 

python. lip 144321 bytes 

D _xiS-tip 77547 bytes 

O Xig py 19015 bytes 


( aiwQ 
► Auto-start Settin gs 







• Download the XBee Internet Gateway software . 

• Use an Ethernet cable to conenct the ConnectPort X2 to your router. Determine its IP 
address by using the software on the CD included with the ConnectPort or by checking 
your router's log for the MAC address. 

• The ConnectPort X2's MAC address is printed on the bottom of the unit. 




• Enter the ConnectPort's IP address into your web browser's location bar. 

• Under the Python menu, upload the two XBee Internet Gateway files: xig.py and 

_xig . zip. 

• Click "Auto-start settings" and add xig.py and enable it. Apply those settings. 

• Under the Reboot menu, click "Reboot." 



© Make Projects 



www.makeprojects.com 



Page 4 of 9 



Networked On Air Light 




© Make Projects www.makeprojects.com Page 5 of 9 



Networked On Air Light 



® or* 



D 



CoolTerm_0 



& 



HEX 



Hew Open Save Connect Disconnect Clear Data Options View Hex Help 



+++0K 
ATID AAAA 
OK 

ATDL 
OK 

ATDH 
OK 



wbsernl- A800«nen f 11S20Q 8-N--1 



RTS O DTR O DCD 




• Attach the XBee to the USB 
adapter and launch a terminal 
program such as CoolTerm . 

• Select the port that matches your 
USB adapter and select "Local 
echo" and click OK and then 
"Connect." 

• In the terminal window, type "+++" 
to enter command mode. The 
modem will respond "OK" 

• Command mode is active 
for 10 seconds after you 
type "+++" or hit enter after an AT 
command. If you take too long, 
type the plus signs again to go 
back into command mode. 

• Type atid aaaa to set the PAN 

ID to match your gateway. The 
modem will respond "OK". 

• Type atdl o to set the low byte of 

the destination address to the 
ConnectPort X2, which is the 
coordinator of the network. Zigbee 
Network Coordinators always have 
the low address of 0. The modem 
will respond "OK". 

• Type atdh o to set the high byte 

of the destination address to the 
ConnectPort X2, which is the 
coordinator of the network. Zigbee 
Network Coordinators always have 
the high address of The modem 
will respond "OK". 



© Make Projects 



www.makeprojects.com 



Page 6 of 9 



Networked On Air Light 




K-ew Open 



CwlTerfin_0 






Dp«n Save Connect Disconnect Clear Data Options View Hex 



Help 




+++0K 

ATID AAAA 

OK 

ATDL 

OK 

ATDH 

OK 

ATBD 7 

OK 

ATWR 

OK 



uH}M-fi^-A6Q0*n«ll / 1 15300 8-N-l 



£} RT5 O DTR O PCD 



_ 




• Type atbd 7 and hit Enter to set 

the baud rate to 1 15200. The 
modem will respond "OK". 

• You can check any of the 
settings by typing the 
command without the parameter. 

• When you've confirmed that the 
settings are correct, type atwr to 

write the settings to the modem's 
flash memory. 

• Disconnect and reconnect at 
115200 baud. 

• Type help. The response should 
be information about the XBee 
Internet Gateway. If not, verify the 
ConenctPort and XBee settings. 

• Type in a web address such as 

http : / /www . google . com/ and 

hit Enter. If you see HTML, you've 
configured the XBee Internet 
Gateway correctly. 



© Make Projects 



www.makeprojects.com 



Page 7 of 9 



Networked On Air Light 




• Insert the XBee into the XBee shield and put the XBee shield on the Arduino. 

• Upload the code . 

• Connect the Arduino to the relay board. 

• Using velcro, mount the components inside the panel. 





• Connect the lamp cord and your 5V 
power adapter to the extension 
cord 

• Connect the power to your Arduino. 

• Create a notch in the bottom of the 
wood panel for the extension cord 
so that the panel can sit flush 
against the wall. 



© Make Projects 



www.makeprojects.com 



Page 8 of 9 



Networked On Air Light 




• Insert red light bulb, replace glass fixture cover. 

• Use press-on letters to spell out "On Air" or whatever you want! 

• Add a hook to the back to mount the light on the wall. 



This document was last generated on 201 2-11 -01 01 :30:25 PM. 



© Make Projects 



www.makeprojects.com 



Page 9 of 9